package exp4.test3;

import org.junit.Test;

/**
 * Created by 春旺 on 2017/11/24.
 */
public class MakeGraphTest {
    @Test
    public void addEdged() throws Exception {
        MakeGraph graph = new MakeGraph();
        graph.addVex("a");
        graph.addVex("b");
        graph.addVex("c");
        graph.addVex("d");
        graph.addVex("e");
        Edge edge1 = new Edge(0,4,5);
        Edge edge2 = new Edge(0,1,4);
        Edge edge3 = new Edge(0,2,6);
        Edge edge4 = new Edge(1,4,10);
        Edge edge5 = new Edge(4,2,15);
        Edge edge6 = new Edge(1,3,13);
        Edge edge7 = new Edge(4,3,2);
        Edge edge8 = new Edge(2,3,25);
        graph.addEdged(edge1);
        graph.addEdged(edge2);
        graph.addEdged(edge3);
        graph.addEdged(edge4);
        graph.addEdged(edge5);
        graph.addEdged(edge6);
        graph.addEdged(edge7);
        graph.addEdged(edge8);
    }

}